#include <iostream>
using namespace std;
#define PI 3.1415926

class Point {
	private:
		int x,y;
	public:
		Point(int x = 0,int y = 0){
			this->x = x;
			this->y = y;
		}
		virtual double area(){
			return 0.0;
		}
};

class Circle:public Point {
	private:
		int r;
	public:
		Circle(int x,int y,int R):Point(x,y){
			r = R;
		}
		double area(){
			return PI*r*r;
		}
};

int main(){
	Point A(10,10);
	cout << "A.area:" << A.area() << endl;
	
	Circle B(10,10,20);
	cout << "B.area:" << B.area() << endl;
	
	Point *p;
	p = &B;
	cout << "p->area:" << p->area() << endl;
	
	Point &pp = B;
	cout << "pp.area:" << pp.area() << endl;
	
	return 0;
}
